<template>
<div class="add">
    <h2>新增员工账号</h2>
  <a-form-model layout="inline" :model="formInline" @submit="handleSubmit" @submit.native.prevent>
    <a-form-model-item>
      <a-input v-model="formInline.user" placeholder="姓名">
        <!-- <a-icon slot="prefix" type="user" style="color:rgba(0,0,0,.25)" /> -->
      </a-input>
    </a-form-model-item>
    <br>
    <a-form-model-item>
      <a-input v-model="formInline.nubmer" type="nubmer" placeholder="员工号">
        <!-- <a-icon slot="prefix" type="lock" style="color:rgba(0,0,0,.25)" /> -->
      </a-input>
    </a-form-model-item>
    <br>
     <a-form-model-item>
      <a-input v-model="formInline.section"  placeholder="部门">
      </a-input>
    </a-form-model-item>
    <br>
     <a-form-model-item>
      <a-input v-model="formInline.role"  placeholder="角色">
      </a-input>
    </a-form-model-item>
    <br>
     <a-form-model-item>
      <a-input v-model="formInline.post" placeholder="岗位">
      </a-input>
    </a-form-model-item>
    <br>
    <a-form-model-item>
      <a-input v-model="formInline.territory" placeholder="负责区域">
      </a-input>
    </a-form-model-item>
    <br>
    <a-form-model-item>
      <a-button
        type="primary"
        html-type="submit"
        :disabled="formInline.user === '' || formInline.nubmer === '' || formInline.section ==='' || formInline.role ===''
         || formInline.post=== '' || formInline.territory === '' "
      >
        提交
      </a-button>
    </a-form-model-item>
  </a-form-model>
  </div>
</template>
<script>
export default {
  data() {
    return {
      formInline: {
        user: '',
        password: '',
      },
    };
  },
  methods: {
    handleSubmit() {
      console.log(this.formInline);
    },
  },
};
</script>
<style>
.add{
    width: 300px;
    margin: auto;
    margin-top: 20px;
}
.add{
    background-color: rgb(209, 221, 231);
    border:solid 1px rgb(209, 231, 211);
}
    
</style>